<template>
  <div>
    <h1>用户</h1>
    <p @click="handleClick">我是一个p标签</p>
  </div>
</template>

<script>
export default {
  created() {
    console.log('用户组件创建了');
  },
  destroyed() {
    console.log('用户组件销毁了');
  },
  methods: {
    handleClick(e) {
      e.target.style.color = 'orange';
    },
  },
};
</script>

<style></style>
